<?php
/**
 * Descript 第三方token类
 * User: blue
 * Date: 2018/8/5 12:12
 */

namespace app\api\server;


use app\api\model\CmsUser;

class ThirdAppToken extends BaseToken
{
    /**
     * cms 获取token
     * 验证用户名密码
     * @param string $uname
     * @param string $pwd
     * @return mixed
     * @throws \app\lib\exception\TokenException
     */
    public function cmsGetToken($uname,$pwd){
        $res=CmsUser::userValid($uname,$pwd);
        $token=$this->productToken();
        $this->tokenToCache($res,$token);
        return token;
    }



}